local skel = fk.CreateSkill {
  name = "efengqi__songwei",
  tags = {Skill.Lord},
}

Fk:loadTranslationTable{
  ["efengqi__songwei"] = "颂威",
  [":efengqi__songwei"] = "主公技，其他角色的黑色判定牌生效后，其可以令你摸一张牌，然后若其为魏势力角色，你可以令其摸一张牌。",

  ["#efengqi__songwei-invoke"] = "颂威：你可以令 %src 摸一张牌",

  ["$efengqi__songwei1"] = "千秋万载，一统江山！",
  ["$efengqi__songwei2"] = "仙福永享，寿与天齐！",
}

skel:addEffect(fk.FinishJudge, {
  anim_type = "drawcard",
  can_trigger = function(self, event, target, player, data)
    return player:hasSkill(skel.name) and target ~= player and data.card.color == Card.Black
  end,
  on_cost = function(self, event, target, player, data)
    return player.room:askToSkillInvoke(target, {skill_name = skel.name, prompt = "#efengqi__songwei-invoke:"..player.id})
  end,
  on_use = function(self, event, target, player, data)
    player:drawCards(1, skel.name)
    if not target.dead and not player.dead and target.kingdom == "wei" and
    player.room:askToSkillInvoke(player, { skill_name = skel.name, prompt = "#efengqi__songwei-invoke:"..target.id }) then
      target:drawCards(1, skel.name)
    end
  end,
})



return skel
